package cn.cqs.serivce;

import cn.cqs.Entity.User;
import cn.cqs.dao.RepositoryUser;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.StringUtils;
@Service
public class Userservice implements IUserService {
        @Autowired
        RepositoryUser repositoryUser;

        @Override
        public User findByUsername(String  username) {
            if(!StringUtils.isEmpty(username)){
                return repositoryUser.findByUsername(username);
            }
            return null;
        }
}
